﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Yun.Interface;
using Yun.Response;
using Yun.Util;

namespace Yun.Marketing.Request
{
    /// <summary>
    /// 修改专题参与的商品信息
    /// yun.goods.apply.subject.part.update
    /// </summary>
    public class UpdateApplySubjectRequest : ITopRequest<BoolResultResponse>
    {
        public string GetApiName()
        {
            return "yun.goods.apply.subject.part.update";
        }

        /// <summary>
        /// id
        /// </summary>
        public long Id { get; set; }

        /// <summary>
        /// 商品别名
        /// </summary>
        public string GoodsName { get; set; }

        /// <summary>
        /// 商品图片
        /// </summary>
        public string GoodsImg { get; set; }

        /// <summary>
        /// 排序号
        /// </summary>
        public int SortId { get; set; }

        /// <summary>
        /// 自定义推荐
        /// </summary>
        public int Recommend { get; set; }


        public void Validate()
        {
            RequestValidator.ValidateRequired("id", Id);
        }
        public IDictionary<string, string> GetParameters()
        {
            var parameters = new YunDictionary
            {
                {"id", Id},
                {"goodsname", GoodsName},
                {"goodsimg", GoodsImg},
                {"sortid", SortId},
                {"recommend", Recommend}
            };
            return parameters;
        }
    }
}
